package user;

import book.BookList;
import operation.IOperation;

import java.net.PortUnreachableException;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 阿宾
 * Date: 2024-07-22
 * Time: 17:00
 */
public abstract class User {
    protected  String name;//姓名
    public IOperation[] iOperations;

    public User(String name) {
        this.name = name;
    }

    public abstract int menu();//不用实现，所以可以加abstract，需要改为抽象方法

    public void doOperation(int choice, BookList bookList){
        iOperations[choice].work(bookList);
    }
}
